<!DOCTYPE html>
<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>highlight.stan</title>
<meta name="generator" content="KF5::SyntaxHighlighting (Stan)"/>
</head><body style="color:#1f1c1b"><pre>
<span style="color:#898887;">/* Stan Highlighting Example</span>

<span style="color:#898887;">  This file contains a syntatically correct but nonsensical Stan program that</span>
<span style="color:#898887;">  includes almost every feature of the language needed to validate syntax</span>
<span style="color:#898887;">  highlighters. It will compile (as of Stan 2.17.1), but it does nothing</span>
<span style="color:#898887;">  useful.</span>

<span style="color:#898887;">  Author: Jeffrey Arnold &lt;jeffrey.anold@gmail.com&gt;</span>
<span style="color:#898887;">  Copyright: Jeffrey Arnold (2018)</span>
<span style="color:#898887;">  License: MIT</span>

<span style="color:#898887;">*/</span>
<span style="color:#898887;">// line comment</span>
<span style="color:#898887;"># deprecated line comment</span>
<span style="font-weight:bold;">functions</span> {
  <span style="color:#898887;">#include stuff.stan</span>
  <span style="color:#898887;">#include &quot;morestuff.stan&quot;</span>
  <span style="color:#898887;">#include 'moststuff.stan'</span>
  <span style="color:#898887;">#include &lt;evenmorestuff.stan&gt;</span>

  <span style="color:#898887;">// declarations</span>
  <span style="color:#0057ae;">void</span> oof(<span style="color:#0057ae;">real</span> x);

  <span style="color:#898887;">// definitions</span>
  <span style="color:#898887;">// return types</span>
  <span style="color:#0057ae;">void</span> oof(<span style="color:#0057ae;">real</span> x) {
    <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;print &quot;</span>, x);
  }
  <span style="color:#898887;">/*</span>
<span style="color:#898887;">    </span><span style="color:#ca60ca;">@param</span><span style="color:#898887;"> x A number</span>
<span style="color:#898887;">    </span><span style="color:#ca60ca;">@return</span><span style="color:#898887;"> x + 1</span>
<span style="color:#898887;">  */</span>
  <span style="color:#0057ae;">real</span> foo(<span style="color:#0057ae;">real</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">int</span> bar(<span style="color:#0057ae;">int</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">vector</span> baz(<span style="color:#0057ae;">vector</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">row_vector</span> qux(<span style="color:#0057ae;">row_vector</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">matrix</span> quux(<span style="color:#0057ae;">matrix</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#898887;">// numbers of arguments</span>
  <span style="color:#0057ae;">void</span> corge() {
    <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;no parameters&quot;</span>);
  }
  <span style="color:#0057ae;">void</span> grault(<span style="color:#0057ae;">int</span> a, <span style="color:#0057ae;">real</span> b, <span style="color:#0057ae;">vector</span> c, <span style="color:#0057ae;">row_vector</span> d, <span style="color:#0057ae;">matrix</span> f) {
    <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;many parameters&quot;</span>);
  }
  <span style="color:#0057ae;">void</span> garply(<span style="color:#0057ae;">real</span> a, <span style="color:#0057ae;">real</span>[] b, <span style="color:#0057ae;">real</span>[,] c, <span style="color:#0057ae;">real</span>[,,] d) {
    <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;array arguments&quot;</span>);
  }
  <span style="color:#898887;">// array return types</span>
  <span style="color:#0057ae;">int</span>[] waldo(<span style="color:#0057ae;">int</span>[] x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">int</span>[,] fred(<span style="color:#0057ae;">int</span>[,] x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#0057ae;">int</span>[,,] plough(<span style="color:#0057ae;">int</span>[,,] x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#898887;">// data only function argument</span>
  <span style="color:#0057ae;">real</span> plugh(<span style="font-weight:bold;">data</span> <span style="color:#0057ae;">real</span> x) {
    <span style="font-weight:bold;">return</span> x;
  }
  <span style="color:#898887;">// ode function</span>
  <span style="color:#0057ae;">real</span>[] ode_func(<span style="color:#0057ae;">real</span> a, <span style="color:#0057ae;">real</span>[] b, <span style="color:#0057ae;">real</span>[] c, <span style="color:#0057ae;">real</span>[] d, <span style="color:#0057ae;">int</span>[] e) {
    <span style="font-weight:bold;">return</span> b;
  }
}
<span style="font-weight:bold;">data</span> {
  <span style="color:#898887;">// non-int variable types</span>
  <span style="color:#0057ae;">int</span> x_int;
  <span style="color:#0057ae;">real</span> x_real;
  <span style="color:#0057ae;">real</span> y_real;
  <span style="color:#0057ae;">vector</span>[<span style="color:#b08000;">1</span>] x_vector;
  <span style="color:#0057ae;">ordered</span>[<span style="color:#b08000;">1</span>] x_ordered;
  <span style="color:#0057ae;">positive_ordered</span>[<span style="color:#b08000;">1</span>] x_positive_ordered;
  <span style="color:#0057ae;">simplex</span>[<span style="color:#b08000;">1</span>] x_simplex;
  <span style="color:#0057ae;">unit_vector</span>[<span style="color:#b08000;">1</span>] x_unit_vector;
  <span style="color:#0057ae;">row_vector</span>[<span style="color:#b08000;">1</span>] x_row_vector;
  <span style="color:#0057ae;">matrix</span>[<span style="color:#b08000;">1</span>, <span style="color:#b08000;">1</span>] x_matrix;
  <span style="color:#0057ae;">cholesky_factor_corr</span>[<span style="color:#b08000;">2</span>] x_cholesky_factor_corr;
  <span style="color:#0057ae;">cholesky_factor_cov</span>[<span style="color:#b08000;">2</span>] x_cholesky_factor_cov;
  <span style="color:#0057ae;">cholesky_factor_cov</span>[<span style="color:#b08000;">2</span>, <span style="color:#b08000;">3</span>] x_cholesky_factor_cov_2;
  <span style="color:#0057ae;">corr_matrix</span>[<span style="color:#b08000;">2</span>] x_corr_matrix;
  <span style="color:#0057ae;">cov_matrix</span>[<span style="color:#b08000;">2</span>] x_cov_matrix;

  <span style="color:#898887;">// range constraints</span>
  <span style="color:#0057ae;">real</span>&lt;<span style="font-weight:bold;">lower</span> = <span style="color:#b08000;">0.</span>, <span style="font-weight:bold;">upper</span> = <span style="color:#b08000;">1.</span>&gt; alpha;
  <span style="color:#0057ae;">real</span>&lt;<span style="font-weight:bold;">lower</span> = <span style="color:#b08000;">0.</span>&gt; bravo;
  <span style="color:#0057ae;">real</span>&lt;<span style="font-weight:bold;">upper</span> = <span style="color:#b08000;">1.</span>&gt; charlie;

  <span style="color:#898887;">// arrays</span>
  <span style="color:#0057ae;">int</span> echo[<span style="color:#b08000;">1</span>];
  <span style="color:#0057ae;">int</span> foxtrot[<span style="color:#b08000;">1</span>, <span style="color:#b08000;">1</span>];
  <span style="color:#0057ae;">int</span> golf[<span style="color:#b08000;">1</span>, <span style="color:#b08000;">1</span>, <span style="color:#b08000;">1</span>];

  <span style="color:#898887;">// identifier with all valid letters</span>
  <span style="color:#0057ae;">real</span> abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_0123456789;

  <span style="color:#898887;">// hard pattern</span>
  <span style="color:#0057ae;">real</span>&lt;<span style="font-weight:bold;">lower</span> = (bravo &lt; charlie), <span style="font-weight:bold;">upper</span> = (bravo &gt; charlie)&gt; ranger;

  <span style="color:#898887;">// identifier patterns</span>
  <span style="color:#0057ae;">real</span> a;
  <span style="color:#0057ae;">real</span> a3;
  <span style="color:#0057ae;">real</span> a_3;
  <span style="color:#0057ae;">real</span> Sigma;
  <span style="color:#0057ae;">real</span> my_cpp_style_variable;
  <span style="color:#0057ae;">real</span> myCamelCaseVariable;
  <span style="color:#0057ae;">real</span> abcdefghijklmnojk;
  <span style="color:#898887;">// names beginning with keywords</span>
  <span style="color:#0057ae;">real</span> iffffff;
  <span style="color:#0057ae;">real</span> whilest;
  <span style="color:#898887;">// name ending with truncation</span>
  <span style="color:#0057ae;">real</span> fooT;
}
<span style="font-weight:bold;">transformed data</span> {
  <span style="color:#898887;">// declaration and assignment</span>
  <span style="color:#0057ae;">int</span> india = <span style="color:#b08000;">1</span>;
  <span style="color:#0057ae;">real</span> romeo = <span style="color:#b08000;">1.0</span>;
  <span style="color:#0057ae;">row_vector</span>[<span style="color:#b08000;">2</span>] victor = [<span style="color:#b08000;">1</span>, <span style="color:#b08000;">2</span>];
  <span style="color:#0057ae;">matrix</span>[<span style="color:#b08000;">2</span>, <span style="color:#b08000;">2</span>] mike = [[<span style="color:#b08000;">1</span>, <span style="color:#b08000;">2</span>], [<span style="color:#b08000;">3</span>, <span style="color:#b08000;">4</span>]];
  <span style="color:#0057ae;">real</span> sierra[<span style="color:#b08000;">2</span>] = {<span style="color:#b08000;">1.</span>, <span style="color:#b08000;">2.</span>};
}
<span style="font-weight:bold;">parameters</span> {
  <span style="color:#0057ae;">real</span> hotel;
}
<span style="font-weight:bold;">transformed parameters</span> {
  <span style="color:#0057ae;">real</span> juliette;
  juliette = hotel * <span style="color:#b08000;">2.</span>;
}
<span style="font-weight:bold;">model</span> {
  <span style="color:#0057ae;">real</span> x;
  <span style="color:#0057ae;">int</span> k;
  <span style="color:#0057ae;">vector</span>[<span style="color:#b08000;">2</span>] y = [<span style="color:#b08000;">1.</span>, <span style="color:#b08000;">1.</span>]';
  <span style="color:#0057ae;">matrix</span>[<span style="color:#b08000;">2</span>, <span style="color:#b08000;">2</span>] A = [[<span style="color:#b08000;">1.</span>, <span style="color:#b08000;">1.</span>], [<span style="color:#b08000;">1.</span>, <span style="color:#b08000;">1.</span>]];
  <span style="color:#0057ae;">real</span> odeout[<span style="color:#b08000;">2</span>, <span style="color:#b08000;">2</span>];
  <span style="color:#0057ae;">real</span> algout[<span style="color:#b08000;">2</span>, <span style="color:#b08000;">2</span>];

  <span style="color:#898887;">// if else statements</span>
  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) x = <span style="color:#b08000;">0.</span>;

  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) {
    x = <span style="color:#b08000;">0.</span>;
  }

  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) x = <span style="color:#b08000;">0.</span>;
  <span style="font-weight:bold;">else</span> x = <span style="color:#b08000;">1.</span>;

  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) {
    x = <span style="color:#b08000;">0.</span>;
  } <span style="font-weight:bold;">else</span> {
    x = <span style="color:#b08000;">1.</span>;
  }

  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) x = <span style="color:#b08000;">0.</span>;
  <span style="font-weight:bold;">else</span> <span style="font-weight:bold;">if</span> (x_real &gt; <span style="color:#b08000;">1</span>) x = <span style="color:#b08000;">1.</span>;
  <span style="font-weight:bold;">else</span> x = <span style="color:#b08000;">0.5</span>;

  <span style="font-weight:bold;">if</span> (x_real &lt; <span style="color:#b08000;">0</span>) {
    x = <span style="color:#b08000;">0.</span>;
  } <span style="font-weight:bold;">else</span> <span style="font-weight:bold;">if</span> (x_real &gt; <span style="color:#b08000;">1</span>) {
    x = <span style="color:#b08000;">1.</span>;
  } <span style="font-weight:bold;">else</span> {
    x = <span style="color:#b08000;">0.5</span>;
  }

  <span style="color:#898887;">// for loops</span>
  <span style="font-weight:bold;">for</span> (i <span style="font-weight:bold;">in</span> <span style="color:#b08000;">1</span>:<span style="color:#b08000;">5</span>) {
    <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;i = &quot;</span>, i);
  }
  <span style="color:#898887;">// for (j in echo) {</span>
  <span style="color:#898887;">//   print(&quot;j = &quot;, j);</span>
  <span style="color:#898887;">// }</span>
  <span style="color:#898887;">// while loop</span>
  <span style="font-weight:bold;">while</span> (<span style="color:#b08000;">1</span>) {
    <span style="font-weight:bold;">break</span>;
    <span style="font-weight:bold;">continue</span>;
  }

  <span style="color:#898887;">// reject statement</span>
  <span style="font-weight:bold;">reject</span>(<span style="color:#bf0303;">&quot;reject statment &quot;</span>, x_real);

  <span style="color:#898887;">// print statement</span>
  <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;print statement &quot;</span>, x_real);
  <span style="font-weight:bold;">print</span>(<span style="color:#bf0303;">&quot;abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_~@#$%^&amp;*`'-+={}[].,;: &quot;</span>);

  <span style="color:#898887;">// increment log probability statements;</span>
  <span style="font-weight:bold;">target +=</span> <span style="color:#b08000;">1.</span>;

  <span style="color:#898887;">// valid integer literals</span>
  k = <span style="color:#b08000;">0</span>;
  k = <span style="color:#b08000;">1</span>;
  k = -<span style="color:#b08000;">1</span>;
  k = <span style="color:#b08000;">256</span>;
  k = -<span style="color:#b08000;">127098</span>;
  k = <span style="color:#b08000;">007</span>;

  <span style="color:#898887;">// valid real literals</span>
  x = <span style="color:#b08000;">0.0</span>;
  x = <span style="color:#b08000;">1.0</span>;
  x = <span style="color:#b08000;">3.14</span>;
  x = <span style="color:#b08000;">003.14</span>;
  x = -<span style="color:#b08000;">217.9387</span>;
  x = <span style="color:#b08000;">0.123</span>;
  x = <span style="color:#b08000;">.123</span>;
  x = <span style="color:#b08000;">1.</span>;
  x = -<span style="color:#b08000;">0.123</span>;
  x = -<span style="color:#b08000;">.123</span>;
  x = -<span style="color:#b08000;">1.</span>;
  x = <span style="color:#b08000;">12</span>e34;
  x = <span style="color:#b08000;">12</span>E34;
  x = <span style="color:#b08000;">12.e34</span>;
  x = <span style="color:#b08000;">12.E34</span>;
  x = <span style="color:#b08000;">12.0e34</span>;
  x = <span style="color:#b08000;">12.0E34</span>;
  x = <span style="color:#b08000;">.1e34</span>;
  x = <span style="color:#b08000;">.1E34</span>;
  x = -<span style="color:#b08000;">12</span>e34;
  x = -<span style="color:#b08000;">12</span>E34;
  x = -<span style="color:#b08000;">12.e34</span>;
  x = -<span style="color:#b08000;">12.E34</span>;
  x = -<span style="color:#b08000;">12.0e34</span>;
  x = -<span style="color:#b08000;">12.0E34</span>;
  x = -<span style="color:#b08000;">.1e34</span>;
  x = -<span style="color:#b08000;">.1E34</span>;
  x = <span style="color:#b08000;">12</span>e-<span style="color:#b08000;">34</span>;
  x = <span style="color:#b08000;">12</span>E-<span style="color:#b08000;">34</span>;
  x = <span style="color:#b08000;">12.e-34</span>;
  x = <span style="color:#b08000;">12.E-34</span>;
  x = <span style="color:#b08000;">12.0e-34</span>;
  x = <span style="color:#b08000;">12.0E-34</span>;
  x = <span style="color:#b08000;">.1e-34</span>;
  x = <span style="color:#b08000;">.1E-34</span>;
  x = -<span style="color:#b08000;">12</span>e-<span style="color:#b08000;">34</span>;
  x = -<span style="color:#b08000;">12</span>E-<span style="color:#b08000;">34</span>;
  x = -<span style="color:#b08000;">12.e-34</span>;
  x = -<span style="color:#b08000;">12.E-34</span>;
  x = -<span style="color:#b08000;">12.0e-34</span>;
  x = -<span style="color:#b08000;">12.0E-34</span>;
  x = -<span style="color:#b08000;">.1e-34</span>;
  x = -<span style="color:#b08000;">.1E-34</span>;
  x = <span style="color:#b08000;">12</span>e+<span style="color:#b08000;">34</span>;
  x = <span style="color:#b08000;">12</span>E+<span style="color:#b08000;">34</span>;
  x = <span style="color:#b08000;">12.e+34</span>;
  x = <span style="color:#b08000;">12.E+34</span>;
  x = <span style="color:#b08000;">12.0e+34</span>;
  x = <span style="color:#b08000;">12.0E+34</span>;
  x = <span style="color:#b08000;">.1e+34</span>;
  x = <span style="color:#b08000;">.1E+34</span>;
  x = -<span style="color:#b08000;">12</span>e+<span style="color:#b08000;">34</span>;
  x = -<span style="color:#b08000;">12</span>E+<span style="color:#b08000;">34</span>;
  x = -<span style="color:#b08000;">12.e+34</span>;
  x = -<span style="color:#b08000;">12.E+34</span>;
  x = -<span style="color:#b08000;">12.0e+34</span>;
  x = -<span style="color:#b08000;">12.0E+34</span>;
  x = -<span style="color:#b08000;">.1e+34</span>;
  x = -<span style="color:#b08000;">.1E+34</span>;

  <span style="color:#898887;">// assignment statements</span>
  x = <span style="color:#b08000;">1</span>;
  x += <span style="color:#b08000;">1.</span>;
  x -= <span style="color:#b08000;">1.</span>;
  x *= <span style="color:#b08000;">1.</span>;
  x /= <span style="color:#b08000;">1.</span>;
  y .*= x_vector;
  y ./= x_vector;

  <span style="color:#898887;">// operators</span>
  x = x_real &amp;&amp; <span style="color:#b08000;">1</span>;
  x = x_real || <span style="color:#b08000;">1</span>;
  x = x_real &lt; <span style="color:#b08000;">1.</span>;
  x = x_real &lt;= <span style="color:#b08000;">1.</span>;
  x = x_real &gt; <span style="color:#b08000;">1.</span>;
  x = x_real &gt;= <span style="color:#b08000;">1.</span>;
  x = x_real + <span style="color:#b08000;">1.</span>;
  x = x_real - <span style="color:#b08000;">1.</span>;
  x = x_real * <span style="color:#b08000;">1.</span>;
  x = x_real / <span style="color:#b08000;">1.</span>;
  x = x_real ^ <span style="color:#b08000;">2.</span>;
  x = x_real % <span style="color:#b08000;">2</span>;
  x = !x_real;
  x = +x_real;
  x = -x_real;
  x = x_int ? x_real : <span style="color:#b08000;">0.</span>;

  y = x_row_vector';
  y = x_matrix \ x_vector;
  y = x_vector .* x_vector;
  y = x_vector ./ x_vector;

  <span style="color:#898887;">// parenthized expression</span>
  x = (x_real + x_real);

  <span style="color:#898887;">// block statement</span>
  {
    <span style="color:#0057ae;">real</span> z;
    z = <span style="color:#b08000;">1.</span>;
  }

  <span style="color:#898887;">// built-in functions</span>
  x = log(<span style="color:#b08000;">1.</span>);
  x = exp(<span style="color:#b08000;">1.</span>);

  <span style="color:#898887;">// non-built-in function</span>
  x = foo(<span style="color:#b08000;">1.</span>);

  <span style="color:#898887;">// constants and nullary functions</span>
  x = machine_precision();
  x = pi();
  x = e();
  x = sqrt2();
  x = log2();
  x = log10();
  <span style="color:#898887;">// special values</span>
  x = not_a_number();
  x = positive_infinity();
  x = negative_infinity();
  x = machine_precision();
  <span style="color:#898887;">// log probability</span>
  x = target();

  <span style="color:#898887;">// sampling statement</span>
  x_real ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);

  <span style="color:#898887;">// truncation</span>
  x_real ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>) <span style="font-weight:bold;">T</span>[-<span style="color:#b08000;">1.</span>, <span style="color:#b08000;">1.</span>];
  x_real ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>) <span style="font-weight:bold;">T</span>[, <span style="color:#b08000;">1.</span>];
  x_real ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>) <span style="font-weight:bold;">T</span>[-<span style="color:#b08000;">1.</span>, ];
  x_real ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>) <span style="font-weight:bold;">T</span>[ , ];

  <span style="color:#898887;">// transformation on lhs of sampling</span>
  log(x_real) ~ normal(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);

  <span style="color:#898887;">// lhs indexes</span>
  y[<span style="color:#b08000;">1</span>] = <span style="color:#b08000;">1.</span>;
  A[<span style="color:#b08000;">1</span>, <span style="color:#b08000;">2</span>] = <span style="color:#b08000;">1.</span>;
  A[<span style="color:#b08000;">1</span>][<span style="color:#b08000;">2</span>] = <span style="color:#b08000;">1.</span>;

  <span style="color:#898887;">// special functions</span>
  odeout = <span style="font-weight:bold;">integrate_ode</span>(ode_func, {<span style="color:#b08000;">1.</span>}, x_real, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">0</span>});
  odeout = <span style="font-weight:bold;">integrate_ode_bdf</span>(ode_func, {<span style="color:#b08000;">1.</span>}, x_real, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">0</span>},
                             x_real, x_real, x_int);
  odeout = <span style="font-weight:bold;">integrate_ode_rk45</span>(ode_func, {<span style="color:#b08000;">1.</span>}, x_real, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">1.</span>}, {<span style="color:#b08000;">0</span>},
                              x_real, x_real, x_int);
  <span style="color:#898887;">// algout = algebra_solver(algebra_func, x_vector, x_vector, {1.}, {0});</span>

  <span style="color:#898887;">// distribution functions</span>
  x = normal_lpdf(<span style="color:#b08000;">0.5</span> | <span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);
  x = normal_cdf(<span style="color:#b08000;">0.5</span>, <span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);
  x = normal_lcdf(<span style="color:#b08000;">0.5</span> | <span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);
  x = normal_lccdf(<span style="color:#b08000;">0.5</span> | <span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);
  x = binomial_lpmf(<span style="color:#b08000;">1</span> | <span style="color:#b08000;">2</span>, <span style="color:#b08000;">0.5</span>);

  <span style="color:#898887;">// deprecated features</span>
  foo &lt;- <span style="color:#b08000;">1</span>;
  increment_log_prob(<span style="color:#b08000;">0.0</span>);
  y_hat = <span style="font-weight:bold;">integrate_ode</span>(sho, y0, t0, ts, theta, x_r, x_i);
  x = get_lp();
  x = multiply_log(<span style="color:#b08000;">1.0</span>, <span style="color:#b08000;">1.0</span>);
  x = binomial_coefficient_log(<span style="color:#b08000;">1.0</span>, <span style="color:#b08000;">1.0</span>);
  <span style="color:#898887;">// deprecated distribution functions versions</span>
  x = normal_log(<span style="color:#b08000;">0.5</span>, <span style="color:#b08000;">0.0</span>, <span style="color:#b08000;">1.0</span>);
  x = normal_cdf_log(<span style="color:#b08000;">0.5</span>, <span style="color:#b08000;">0.0</span>, <span style="color:#b08000;">1.0</span>);
  x = normal_ccdf_log(<span style="color:#b08000;">0.5</span>, <span style="color:#b08000;">0.0</span>, <span style="color:#b08000;">1.0</span>);

}
<span style="font-weight:bold;">generated quantities</span> {
  <span style="color:#0057ae;">real</span> Y;
  <span style="color:#898887;">// rng function</span>
  Y = normal_rng(<span style="color:#b08000;">0.</span>, <span style="color:#b08000;">1.</span>);
}
</pre></body></html>
